home *** CD-ROM | disk | FTP | other *** search
MacBinary | 1995-01-22 | 10.0 KB | [ TEXT/MMCC]
open in: MacOS 8.1
extracted
|
Win98
extracted
|
DOS
extracted
browse contents |
view JSON data
|
view as text
This file was processed as: MacBinary
(archive/macBinary ).
Confidence Program Detection Match Type Support
66%
dexvert
Compact Compressed (Unix) (archive/compact)
ext
Supported
20%
dexvert
Blazing Paddles (image/blazingPaddles)
fileSize
Supported
10%
dexvert
MacBinary (archive/macBinary)
fallback
Supported
1%
dexvert
Text File (text/txt)
fallback
Supported
100%
file
MacBinary II, Sun Jan 22 14:07:14 1995, modified Sun Jan 22 14:07:14 1995, creator 'MMCC', type ASCII, 9437 bytes "CopyWindows.c" , at 0x255d 594 bytes resource
default (weak)
99%
file
data
default
74%
TrID
Macintosh plain text (MacBinary)
default
25%
TrID
MacBinary 2
default (weak)
100%
siegfried
fmt/1762 MacBinary (II)
default
100%
lsar
MacBinary
default
id metadata key value macFileType [ TEXT] macFileCreator [ MMCC]
hex view +--------+-------------------------+-------------------------+--------+--------+ |00000000| 00 0d 43 6f 70 79 57 69 | 6e 64 6f 77 73 2e 63 00 |..CopyWi|ndows.c.| |00000010| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........| |00000020| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........| |00000030| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........| |00000040| 00 54 45 58 54 4d 4d 43 | 43 00 00 00 00 00 00 00 |.TEXTMMC|C.......| |00000050| 00 00 00 00 00 24 dd 00 | 00 02 52 ab 48 5d 62 ab |.....$..|..R.H]b.| |00000060| 48 5d 62 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |H]b.....|........| |00000070| 00 00 00 00 00 00 00 00 | 00 00 81 81 ae f7 00 00 |........|........| |00000080| 2f 2a 0d 43 6f 70 79 57 | 69 6e 64 6f 77 73 2e 63 |/*.CopyW|indows.c| |00000090| 0d 0d 43 6f 70 79 57 69 | 6e 64 6f 77 73 28 73 72 |..CopyWi|ndows(sr| |000000a0| 63 57 69 6e 64 6f 77 2c | 64 73 74 57 69 6e 64 6f |cWindow,|dstWindo| |000000b0| 77 2c 73 72 63 52 65 63 | 74 50 74 72 2c 64 73 74 |w,srcRec|tPtr,dst| |000000c0| 52 65 63 74 50 74 72 2c | 73 72 63 4d 6f 64 65 2c |RectPtr,|srcMode,| |000000d0| 6d 61 73 6b 52 67 6e 29 | 3b 0d 0d 43 6f 70 79 57 |maskRgn)|;..CopyW| |000000e0| 69 6e 64 6f 77 73 28 29 | 20 70 72 6f 76 69 64 65 |indows()| provide| |000000f0| 73 20 61 20 68 69 67 68 | 2d 6c 65 76 65 6c 20 69 |s a high|-level i| |00000100| 6e 74 65 72 66 61 63 65 | 20 74 6f 20 43 6f 70 79 |nterface| to Copy| |00000110| 42 69 74 73 20 61 6e 64 | 20 43 6f 70 79 42 69 74 |Bits and| CopyBit| |00000120| 73 51 75 69 63 6b 6c 79 | 2c 0d 61 63 63 65 70 74 |sQuickly|,.accept| |00000130| 69 6e 67 20 77 69 6e 64 | 6f 77 73 20 28 57 69 6e |ing wind|ows (Win| |00000140| 64 6f 77 50 74 72 2c 20 | 43 57 69 6e 64 6f 77 50 |dowPtr, |CWindowP| |00000150| 74 72 2c 20 6f 72 20 47 | 57 6f 72 6c 64 50 74 72 |tr, or G|WorldPtr| |00000160| 29 20 69 6e 73 74 65 61 | 64 20 6f 66 20 70 69 78 |) instea|d of pix| |00000170| 6d 61 70 73 20 6f 72 0d | 62 69 74 6d 61 70 73 2e |maps or.|bitmaps.| |00000180| 0d 0d 59 6f 75 20 73 65 | 6c 65 63 74 20 43 6f 70 |..You se|lect Cop| |00000190| 79 42 69 74 73 51 75 69 | 63 6b 6c 79 20 62 79 20 |yBitsQui|ckly by | |000001a0| 75 73 69 6e 67 20 61 20 | 73 72 63 4d 6f 64 65 20 |using a |srcMode | |000001b0| 74 68 61 74 20 68 61 73 | 20 74 68 65 20 22 63 6f |that has| the "co| |000001c0| 70 79 4c 69 74 65 72 61 | 6c 6c 79 22 20 62 69 74 |pyLitera|lly" bit| |000001d0| 0d 73 65 74 2c 20 69 2e | 65 2e 20 65 69 74 68 65 |.set, i.|e. eithe| |000001e0| 72 20 73 72 63 43 6f 70 | 79 4c 69 74 65 72 61 6c |r srcCop|yLiteral| |000001f0| 6c 79 2c 20 61 64 64 4f | 76 65 72 4c 69 74 65 72 |ly, addO|verLiter| |00000200| 61 6c 6c 79 2c 20 61 64 | 64 4f 76 65 72 50 61 72 |ally, ad|dOverPar| |00000210| 61 6c 6c 65 6c 4c 69 74 | 65 72 61 6c 6c 79 2c 0d |allelLit|erally,.| |00000220| 6f 72 20 6d 75 6c 4f 76 | 65 72 4c 69 74 65 72 61 |or mulOv|erLitera| |00000230| 6c 6c 79 2e 0d 0d 46 6f | 72 20 79 6f 75 72 20 63 |lly...Fo|r your c| |00000240| 6f 6e 76 65 6e 69 65 6e | 63 65 2c 20 43 6f 70 79 |onvenien|ce, Copy| |00000250| 57 69 6e 64 6f 77 73 20 | 6e 6f 72 6d 61 6c 6c 79 |Windows |normally| |00000260| 20 73 65 74 73 20 75 70 | 20 74 68 65 20 66 6f 72 | sets up| the for| |00000270| 65 67 72 6f 75 6e 64 20 | 61 6e 64 20 62 61 63 6b |eground |and back| |00000280| 67 72 6f 75 6e 64 0d 63 | 6f 6c 6f 72 73 20 74 6f |ground.c|olors to| |00000290| 20 70 72 65 76 65 6e 74 | 20 75 6e 64 65 73 69 72 | prevent| undesir| |000002a0| 65 64 20 63 6f 6c 6f 72 | 69 7a 69 6e 67 2e 20 49 |ed color|izing. I| |000002b0| 66 20 79 6f 75 20 77 61 | 6e 74 20 74 6f 20 63 6f |f you wa|nt to co| |000002c0| 6c 6f 72 69 7a 65 20 74 | 68 65 6e 20 61 64 64 0d |lorize t|hen add.| |000002d0| 22 63 6f 70 79 43 6f 6c | 6f 72 69 7a 65 22 20 74 |"copyCol|orize" t| |000002e0| 6f 20 74 68 65 20 73 72 | 63 4d 6f 64 65 20 61 72 |o the sr|cMode ar| |000002f0| 67 75 6d 65 6e 74 2e 0d | 0d 43 6f 70 79 42 69 74 |gument..|.CopyBit| |00000300| 73 28 29 20 69 73 20 61 | 6e 20 65 78 74 72 65 6d |s() is a|n extrem| |00000310| 65 6c 79 20 75 73 65 66 | 75 6c 20 63 6f 6d 70 6f |ely usef|ul compo| |00000320| 6e 65 6e 74 20 6f 66 20 | 51 75 69 63 6b 44 72 61 |nent of |QuickDra| |00000330| 77 2c 20 62 75 74 20 69 | 74 27 73 20 74 72 69 63 |w, but i|t's tric| |00000340| 6b 79 20 74 6f 0d 75 73 | 65 2c 20 65 73 70 65 63 |ky to.us|e, espec| |00000350| 69 61 6c 6c 79 20 69 66 | 20 79 6f 75 20 6a 75 73 |ially if| you jus| |00000360| 74 20 77 61 6e 74 20 61 | 20 66 61 69 74 68 66 75 |t want a| faithfu| |00000370| 6c 20 63 6f 70 79 2e 20 | 49 74 73 20 75 73 65 72 |l copy. |Its user| |00000380| 2d 69 6e 74 65 72 66 61 | 63 65 20 77 61 73 20 66 |-interfa|ce was f| |00000390| 72 6f 7a 65 6e 0d 61 20 | 6c 6f 6e 67 20 74 69 6d |rozen.a |long tim| |000003a0| 65 20 61 67 6f 2c 20 77 | 68 65 6e 20 6f 66 66 2d |e ago, w|hen off-| |000003b0| 73 63 72 65 65 6e 20 69 | 6d 61 67 65 73 20 77 65 |screen i|mages we| |000003c0| 72 65 20 72 65 66 65 72 | 72 65 64 20 74 6f 20 62 |re refer|red to b| |000003d0| 79 20 74 68 65 69 72 20 | 42 69 74 4d 61 70 0d 70 |y their |BitMap.p| |000003e0| 6f 69 6e 74 65 72 73 2e | 20 41 70 70 6c 65 20 67 |ointers.| Apple g| |000003f0| 65 6e 65 72 61 6c 69 7a | 65 64 20 69 74 73 20 75 |eneraliz|ed its u| |00000400| 6e 64 65 72 6c 79 69 6e | 67 20 63 6f 64 65 20 74 |nderlyin|g code t| |00000410| 6f 20 61 63 63 65 70 74 | 20 50 69 78 4d 61 70 20 |o accept| PixMap | |00000420| 70 6f 69 6e 74 65 72 73 | 20 61 73 0d 77 65 6c 6c |pointers| as.well| |00000430| 2c 20 62 75 74 20 74 68 | 65 20 72 65 61 6c 69 74 |, but th|e realit| |00000440| 79 20 69 73 20 74 68 61 | 74 20 6e 6f 77 61 64 61 |y is tha|t nowada| |00000450| 79 73 20 74 68 65 20 6f | 62 6a 65 63 74 20 74 68 |ys the o|bject th| |00000460| 61 74 20 77 65 20 77 6f | 72 6b 20 77 69 74 68 20 |at we wo|rk with | |00000470| 69 73 20 61 20 77 69 6e | 64 6f 77 2c 0d 65 69 74 |is a win|dow,.eit| |00000480| 68 65 72 20 6f 6e 2d 73 | 63 72 65 65 6e 2c 20 6f |her on-s|creen, o| |00000490| 72 20 6f 66 66 2d 73 63 | 72 65 65 6e 20 28 69 2e |r off-sc|reen (i.| |000004a0| 65 2e 20 61 20 47 57 6f | 72 6c 64 29 2e 20 43 6f |e. a GWo|rld). Co| |000004b0| 70 79 57 69 6e 64 6f 77 | 73 20 61 63 63 65 70 74 |pyWindow|s accept| |000004c0| 73 20 74 77 6f 0d 77 69 | 6e 64 6f 77 73 2c 20 73 |s two.wi|ndows, s| |000004d0| 6f 75 72 63 65 20 61 6e | 64 20 64 65 73 74 69 6e |ource an|d destin| |000004e0| 61 74 69 6f 6e 2c 20 66 | 69 67 75 72 65 73 20 6f |ation, f|igures o| |000004f0| 75 74 20 77 68 65 72 65 | 20 74 68 65 20 61 73 73 |ut where| the ass| |00000500| 6f 63 69 61 74 65 64 20 | 50 69 78 2f 42 69 74 4d |ociated |Pix/BitM| |00000510| 61 70 73 0d 61 72 65 2c | 20 61 6e 64 20 63 61 6c |aps.are,| and cal| |00000520| 6c 73 20 43 6f 70 79 42 | 69 74 73 20 6f 72 20 43 |ls CopyB|its or C| |00000530| 6f 70 79 42 69 74 73 51 | 75 69 63 6b 6c 79 2c 20 |opyBitsQ|uickly, | |00000540| 61 66 74 65 72 20 6d 61 | 6b 69 6e 67 20 61 6c 6c |after ma|king all| |00000550| 20 74 68 65 20 61 70 70 | 72 6f 70 72 69 61 74 65 | the app|ropriate| |00000560| 0d 69 6e 63 61 6e 74 61 | 74 69 6f 6e 73 20 74 6f |.incanta|tions to| |00000570| 20 67 65 74 20 74 68 65 | 20 64 65 73 69 72 65 64 | get the| desired| |00000580| 20 72 65 73 75 6c 74 73 | 2e 0d 0d 54 68 65 20 61 | results|...The a| |00000590| 6c 6c 6f 77 65 64 20 76 | 61 6c 75 65 73 20 66 6f |llowed v|alues fo| |000005a0| 72 20 73 72 63 4d 6f 64 | 65 20 61 72 65 20 64 6f |r srcMod|e are do| |000005b0| 63 75 6d 65 6e 74 65 64 | 20 62 79 20 41 70 70 6c |cumented| by Appl| |000005c0| 65 20 61 6c 6f 6e 67 20 | 77 69 74 68 20 43 6f 70 |e along |with Cop| |000005d0| 79 42 69 74 73 20 69 6e | 20 74 68 65 0d 4e 65 77 |yBits in| the.New| |000005e0| 20 49 6e 73 69 64 65 20 | 4d 61 63 3a 20 22 49 6d | Inside |Mac: "Im| |000005f0| 61 67 69 6e 67 20 77 69 | 74 68 20 51 75 69 63 6b |aging wi|th Quick| |00000600| 44 72 61 77 22 2e 20 54 | 68 65 20 61 64 64 69 74 |Draw". T|he addit| |00000610| 69 6f 6e 61 6c 20 6d 6f | 64 65 73 20 69 6d 70 6c |ional mo|des impl| |00000620| 65 6d 65 6e 74 65 64 20 | 62 79 0d 43 6f 70 79 42 |emented |by.CopyB| |00000630| 69 74 73 51 75 69 63 6b | 6c 79 20 61 72 65 20 64 |itsQuick|ly are d| |00000640| 6f 63 75 6d 65 6e 74 65 | 64 20 69 6e 20 43 6f 70 |ocumente|d in Cop| |00000650| 79 42 69 74 73 51 75 69 | 63 6b 6c 79 2e 63 2e 20 |yBitsQui|ckly.c. | |00000660| 43 6f 70 79 42 69 74 73 | 20 61 6e 64 0d 43 6f 70 |CopyBits| and.Cop| |00000670| 79 42 69 74 73 51 75 69 | 63 6b 6c 79 20 64 65 66 |yBitsQui|ckly def| |00000680| 69 6e 65 20 73 72 63 4d | 6f 64 65 20 61 73 20 61 |ine srcM|ode as a| |00000690| 20 73 68 6f 72 74 2e 20 | 43 6f 70 79 57 69 6e 64 | short. |CopyWind| |000006a0| 6f 77 73 20 64 65 66 69 | 6e 65 73 20 73 72 63 4d |ows defi|nes srcM| |000006b0| 6f 64 65 20 61 73 20 61 | 0d 6c 6f 6e 67 2c 20 75 |ode as a|.long, u| |000006c0| 73 69 6e 67 20 74 77 6f | 20 62 69 74 73 20 69 6e |sing two| bits in| |000006d0| 20 74 68 65 20 75 70 70 | 65 72 20 77 6f 72 64 20 | the upp|er word | |000006e0| 61 73 20 66 6c 61 67 73 | 20 66 6f 72 20 63 6f 70 |as flags| for cop| |000006f0| 79 4c 69 74 65 72 61 6c | 6c 79 20 61 6e 64 0d 63 |yLiteral|ly and.c| |00000700| 6f 70 79 43 6f 6c 6f 72 | 69 7a 65 2e 20 48 65 72 |opyColor|ize. Her| |00000710| 65 27 73 20 61 20 73 75 | 6d 6d 61 72 79 20 6f 66 |e's a su|mmary of| |00000720| 20 74 68 65 20 6d 6f 64 | 65 73 20 74 68 61 74 20 | the mod|es that | |00000730| 49 20 75 73 65 20 6d 6f | 73 74 3a 0d 0d 73 72 63 |I use mo|st:..src| |00000740| 43 6f 70 79 0d 0d 54 68 | 69 73 20 6d 6f 64 65 20 |Copy..Th|is mode | |00000750| 69 73 20 69 6d 70 6c 65 | 6d 65 6e 74 65 64 20 62 |is imple|mented b| |00000760| 79 20 43 6f 70 79 42 69 | 74 73 2e 20 49 66 20 74 |y CopyBi|ts. If t| |00000770| 68 65 20 73 6f 75 72 63 | 65 20 61 6e 64 20 64 65 |he sourc|e and de| |00000780| 73 74 69 6e 61 74 69 6f | 6e 20 68 61 76 65 20 74 |stinatio|n have t| |00000790| 68 65 0d 73 61 6d 65 20 | 64 65 70 74 68 20 28 69 |he.same |depth (i| |000007a0| 2e 65 2e 20 70 69 78 65 | 6c 53 69 7a 65 29 20 61 |.e. pixe|lSize) a| |000007b0| 6e 64 20 65 78 61 63 74 | 6c 79 20 74 68 65 20 73 |nd exact|ly the s| |000007c0| 61 6d 65 20 63 6f 6c 6f | 72 20 74 61 62 6c 65 20 |ame colo|r table | |000007d0| 74 68 65 6e 20 79 6f 75 | 27 6c 6c 20 67 65 74 0d |then you|'ll get.| |000007e0| 66 61 69 74 68 66 75 6c | 20 63 6f 70 79 69 6e 67 |faithful| copying| |000007f0| 20 6f 66 20 74 68 65 20 | 61 63 74 75 61 6c 20 6e | of the |actual n| |00000800| 75 6d 62 65 72 73 20 73 | 74 6f 72 65 64 20 69 6e |umbers s|tored in| |00000810| 20 65 61 63 68 20 70 69 | 78 65 6c 2e 20 28 49 27 | each pi|xel. (I'| |00000820| 6d 20 61 73 73 75 6d 69 | 6e 67 20 74 68 61 74 0d |m assumi|ng that.| |00000830| 74 68 65 20 64 65 73 74 | 69 6e 61 74 69 6f 6e 20 |the dest|ination | |00000840| 77 69 6e 64 6f 77 20 68 | 61 73 20 74 68 65 20 73 |window h|as the s| |00000850| 61 6d 65 20 63 6f 6c 6f | 72 20 74 61 62 6c 65 20 |ame colo|r table | |00000860| 61 73 20 69 74 73 20 64 | 65 76 69 63 65 2c 20 77 |as its d|evice, w| |00000870| 68 69 63 68 20 77 69 6c | 6c 20 62 65 0d 74 72 75 |hich wil|l be.tru| |00000880| 65 20 69 66 20 79 6f 75 | 20 63 72 65 61 74 65 64 |e if you| created| |00000890| 20 74 68 65 20 77 69 6e | 64 6f 77 20 75 73 69 6e | the win|dow usin| |000008a0| 67 20 47 44 4f 70 65 6e | 57 69 6e 64 6f 77 20 6f |g GDOpen|Window o| |000008b0| 72 20 4e 65 77 47 57 6f | 72 6c 64 2e 29 20 49 66 |r NewGWo|rld.) If| |000008c0| 20 74 68 65 20 73 6f 75 | 72 63 65 0d 61 6e 64 20 | the sou|rce.and | |000008d0| 64 65 73 74 69 6e 61 74 | 69 6f 6e 20 68 61 76 65 |destinat|ion have| |000008e0| 20 64 69 66 66 65 72 65 | 6e 74 20 63 6f 6c 6f 72 | differe|nt color| |000008f0| 20 74 61 62 6c 65 73 2c | 20 65 2e 67 2e 20 62 65 | tables,| e.g. be| |00000900| 63 61 75 73 65 20 74 68 | 65 20 70 69 78 65 6c 20 |cause th|e pixel | |00000910| 73 69 7a 65 73 0d 64 69 | 66 66 65 72 2c 20 74 68 |sizes.di|ffer, th| |00000920| 65 6e 20 43 6f 70 79 42 | 69 74 73 20 77 69 6c 6c |en CopyB|its will| |00000930| 20 74 72 61 6e 73 6c 61 | 74 65 20 76 69 61 20 74 | transla|te via t| |00000940| 68 65 20 63 6f 6c 6f 72 | 20 74 61 62 6c 65 73 2e |he color| tables.| |00000950| 20 43 6f 70 79 42 69 74 | 73 20 69 73 20 70 65 72 | CopyBit|s is per| |00000960| 68 61 70 73 0d 41 70 70 | 6c 65 27 73 20 70 72 69 |haps.App|le's pri| |00000970| 7a 65 20 70 69 65 63 65 | 20 6f 66 20 63 6f 64 65 |ze piece| of code| |00000980| 20 61 6e 64 20 72 75 6e | 73 20 76 65 72 79 20 66 | and run|s very f| |00000990| 61 73 74 2c 20 74 61 6b | 69 6e 67 20 61 64 76 61 |ast, tak|ing adva| |000009a0| 6e 74 61 67 65 20 6f 66 | 20 73 70 65 63 69 61 6c |ntage of| special| |000009b0| 0d 69 6e 73 74 72 75 63 | 74 69 6f 6e 73 20 6f 66 |.instruc|tions of| |000009c0| 20 70 61 72 74 69 63 75 | 6c 61 72 20 70 72 6f 63 | particu|lar proc| |000009d0| 65 73 73 6f 72 73 20 28 | 65 2e 67 2e 20 74 6f 20 |essors (|e.g. to | |000009e0| 64 6f 20 36 34 20 62 69 | 74 20 6d 6f 76 65 73 20 |do 64 bi|t moves | |000009f0| 6f 6e 20 36 38 30 34 30 | 20 61 6e 64 0d 50 6f 77 |on 68040| and.Pow| |00000a00| 65 72 50 43 29 20 61 6e | 64 20 63 61 6e 20 64 6f |erPC) an|d can do| |00000a10| 20 77 6f 6e 64 65 72 66 | 75 6c 20 74 68 69 6e 67 | wonderf|ul thing| |00000a20| 73 2c 20 6c 69 6b 65 20 | 73 74 72 65 74 63 68 20 |s, like |stretch | |00000a30| 61 6e 64 20 73 68 72 69 | 6e 6b 20 61 6e 64 20 6d |and shri|nk and m| |00000a40| 61 73 6b 20 62 79 20 61 | 0d 72 65 67 69 6f 6e 2e |ask by a|.region.| |00000a50| 20 41 70 70 6c 65 20 64 | 65 66 69 6e 65 73 20 6d | Apple d|efines m| |00000a60| 61 6e 79 20 6f 74 68 65 | 72 20 73 72 63 4d 6f 64 |any othe|r srcMod| |00000a70| 65 20 76 61 6c 75 65 73 | 20 62 75 74 20 49 20 6e |e values| but I n| |00000a80| 65 76 65 72 20 75 73 65 | 20 74 68 65 6d 20 77 69 |ever use| them wi| |00000a90| 74 68 0d 43 6f 70 79 42 | 69 74 73 20 62 65 63 61 |th.CopyB|its beca| |00000aa0| 75 73 65 20 74 68 65 79 | 20 61 6c 6c 20 72 65 73 |use they| all res| |00000ab0| 75 6c 74 20 69 6e 20 63 | 6f 6c 6f 72 20 74 72 61 |ult in c|olor tra| |00000ac0| 6e 73 6c 61 74 69 6f 6e | 73 20 74 68 61 74 20 49 |nslation|s that I| |00000ad0| 20 64 6f 6e 27 74 20 77 | 61 6e 74 2e 0d 0d 73 72 | don't w|ant...sr| |00000ae0| 63 43 6f 70 79 4c 69 74 | 65 72 61 6c 6c 79 2c 61 |cCopyLit|erally,a| |00000af0| 64 64 4f 76 65 72 4c 69 | 74 65 72 61 6c 6c 79 2c |ddOverLi|terally,| |00000b00| 61 64 64 4f 76 65 72 50 | 61 72 61 6c 6c 65 6c 4c |addOverP|arallelL| |00000b10| 69 74 65 72 61 6c 6c 79 | 2c 6d 75 6c 4f 76 65 72 |iterally|,mulOver| |00000b20| 4c 69 74 65 72 61 6c 6c | 79 0d 0d 54 68 65 73 65 |Literall|y..These| |00000b30| 20 6d 6f 64 65 73 20 61 | 72 65 20 69 6d 70 6c 65 | modes a|re imple| |00000b40| 6d 65 6e 74 65 64 20 62 | 79 20 43 6f 70 79 42 69 |mented b|y CopyBi| |00000b50| 74 73 51 75 69 63 6b 6c | 79 2c 20 77 68 69 63 68 |tsQuickl|y, which| |00000b60| 20 6e 65 76 65 72 20 64 | 6f 65 73 20 63 6f 6c 6f | never d|oes colo| |00000b70| 72 0d 74 72 61 6e 73 6c | 61 74 69 6f 6e 2e 20 61 |r.transl|ation. a| |00000b80| 64 64 4f 76 65 72 4c 69 | 74 65 72 61 6c 6c 79 20 |ddOverLi|terally | |00000b90| 61 64 64 73 20 74 68 65 | 20 70 69 78 65 6c 20 76 |adds the| pixel v| |00000ba0| 61 6c 75 65 73 2c 20 69 | 67 6e 6f 72 69 6e 67 20 |alues, i|gnoring | |00000bb0| 6f 76 65 72 66 6c 6f 77 | 2e 0d 61 64 64 4f 76 65 |overflow|..addOve| |00000bc0| 72 50 61 72 61 6c 6c 65 | 6c 4c 69 74 65 72 61 6c |rParalle|lLiteral| |00000bd0| 6c 79 20 64 6f 65 73 20 | 74 68 65 20 73 61 6d 65 |ly does |the same| |00000be0| 2c 20 62 75 74 20 64 6f | 65 73 20 74 68 65 20 61 |, but do|es the a| |00000bf0| 64 64 69 74 69 6f 6e 20 | 66 6f 72 20 33 32 2d 62 |ddition |for 32-b| |00000c00| 69 74 73 20 61 74 20 61 | 0d 74 69 6d 65 2c 20 61 |its at a|.time, a| |00000c10| 64 64 69 6e 67 20 73 65 | 76 65 72 61 6c 20 70 69 |dding se|veral pi| |00000c20| 78 65 6c 73 20 61 74 20 | 6f 6e 63 65 2c 20 73 6f |xels at |once, so| |00000c30| 20 74 68 61 74 20 69 66 | 20 6f 76 65 72 66 6c 6f | that if| overflo| |00000c40| 77 20 6f 63 63 75 72 73 | 20 69 74 20 77 69 6c 6c |w occurs| it will| |00000c50| 20 6f 76 65 72 66 6c 6f | 77 0d 69 6e 74 6f 20 61 | overflo|w.into a| |00000c60| 6e 20 61 64 6a 6f 69 6e | 67 20 70 69 78 65 6c 2e |n adjoin|g pixel.| |00000c70| 20 6d 75 6c 4f 76 65 72 | 4c 69 74 65 72 61 6c 6c | mulOver|Literall| |00000c80| 79 20 6d 75 6c 74 69 70 | 6c 69 65 73 20 74 68 65 |y multip|lies the| |00000c90| 20 28 75 6e 73 69 67 6e | 65 64 29 20 70 69 78 65 | (unsign|ed) pixe| |00000ca0| 6c 73 2c 0d 64 69 76 69 | 64 65 73 20 74 68 65 20 |ls,.divi|des the | |00000cb0| 70 72 6f 64 75 63 74 20 | 62 79 20 31 32 38 2c 20 |product |by 128, | |00000cc0| 61 6e 64 20 73 74 6f 72 | 65 73 20 74 68 65 20 72 |and stor|es the r| |00000cd0| 65 73 75 6c 74 20 69 6e | 20 74 68 65 20 64 65 73 |esult in| the des| |00000ce0| 74 69 6e 61 74 69 6f 6e | 2e 0d 43 6f 70 79 42 69 |tination|..CopyBi| |00000cf0| 74 73 51 75 69 63 6b 6c | 79 20 68 61 73 20 6d 61 |tsQuickl|y has ma| |00000d00| 6e 79 20 72 65 73 74 72 | 69 63 74 69 6f 6e 73 2e |ny restr|ictions.| |00000d10| 20 54 68 65 20 73 6f 75 | 72 63 65 20 61 6e 64 20 | The sou|rce and | |00000d20| 64 65 73 74 69 6e 61 74 | 69 6f 6e 20 6d 75 73 74 |destinat|ion must| |00000d30| 20 68 61 76 65 20 74 68 | 65 0d 73 61 6d 65 20 72 | have th|e.same r| |00000d40| 65 63 74 20 73 69 7a 65 | 20 61 6e 64 20 74 68 65 |ect size| and the| |00000d50| 20 73 61 6d 65 20 70 69 | 78 65 6c 20 73 69 7a 65 | same pi|xel size| |00000d60| 2e 20 61 64 64 4f 76 65 | 72 4c 69 74 65 72 61 6c |. addOve|rLiteral| |00000d70| 6c 79 20 61 6e 64 20 6d | 75 6c 4f 76 65 72 4c 69 |ly and m|ulOverLi| |00000d80| 74 65 72 61 6c 6c 79 0d | 69 6e 73 69 73 74 20 6f |terally.|insist o| |00000d90| 6e 20 38 2d 62 69 74 20 | 70 69 78 65 6c 73 2e 20 |n 8-bit |pixels. | |00000da0| 41 6c 6c 20 74 68 65 20 | 6d 6f 64 65 73 20 72 65 |All the |modes re| |00000db0| 73 6f 6c 76 65 20 6f 6e | 6c 79 20 62 79 74 65 73 |solve on|ly bytes| |00000dc0| 2c 20 6e 6f 74 20 62 69 | 74 73 2c 20 73 6f 20 61 |, not bi|ts, so a| |00000dd0| 20 66 65 77 0d 62 69 74 | 73 20 61 74 20 74 68 65 | few.bit|s at the| |00000de0| 20 6c 65 66 74 20 61 6e | 64 20 72 69 67 68 74 20 | left an|d right | |00000df0| 6f 66 20 79 6f 75 72 20 | 69 6d 61 67 65 20 6d 61 |of your |image ma| |00000e00| 79 20 6e 6f 74 20 62 65 | 20 63 6f 70 69 65 64 20 |y not be| copied | |00000e10| 69 66 20 74 68 61 74 20 | 77 6f 75 6c 64 20 72 65 |if that |would re| |00000e20| 71 75 69 72 65 0d 77 72 | 69 74 69 6e 67 20 74 6f |quire.wr|iting to| |00000e30| 20 61 20 62 79 74 65 20 | 6e 6f 74 20 61 6c 6c 20 | a byte |not all | |00000e40| 6f 66 20 77 68 6f 73 65 | 20 62 69 74 73 20 61 72 |of whose| bits ar| |00000e50| 65 20 69 6e 20 74 68 65 | 20 64 65 73 74 69 6e 61 |e in the| destina| |00000e60| 74 69 6f 6e 2e 0d 0d 4e | 4f 54 45 53 3a 0d 0d 30 |tion...N|OTES:..0| |00000e70| 2e 20 52 65 61 64 20 22 | 56 69 64 65 6f 54 6f 6f |. Read "|VideoToo| |00000e80| 6c 62 6f 78 3a 4e 6f 74 | 65 73 3a 43 6f 70 79 42 |lbox:Not|es:CopyB| |00000e90| 69 74 73 20 73 6c 61 76 | 69 73 68 6c 79 22 2e 0d |its slav|ishly"..| |00000ea0| 0d 31 2e 20 43 6f 70 79 | 42 69 74 73 20 68 61 73 |.1. Copy|Bits has| |00000eb0| 20 61 20 72 61 72 65 6c | 79 20 75 73 65 64 20 66 | a rarel|y used f| |00000ec0| 65 61 74 75 72 65 20 63 | 61 6c 6c 65 64 20 22 63 |eature c|alled "c| |00000ed0| 6f 6c 6f 72 69 7a 69 6e | 67 22 20 77 68 65 72 65 |olorizin|g" where| |00000ee0| 62 79 20 69 66 20 74 68 | 65 0d 66 6f 72 65 67 72 |by if th|e.foregr| |00000ef0| 6f 75 6e 64 20 61 6e 64 | 20 62 61 63 6b 67 72 6f |ound and| backgro| |00000f00| 75 6e 64 20 63 6f 6c 6f | 72 73 20 6f 66 20 74 68 |und colo|rs of th| |00000f10| 65 20 63 75 72 72 65 6e | 74 20 70 6f 72 74 20 61 |e curren|t port a| |00000f20| 72 65 20 6e 6f 74 20 62 | 6c 61 63 6b 20 61 6e 64 |re not b|lack and| |00000f30| 20 77 68 69 74 65 0d 74 | 68 65 6e 20 65 61 63 68 | white.t|hen each| |00000f40| 20 73 6f 75 72 63 65 20 | 70 69 78 65 6c 27 73 20 | source |pixel's | |00000f50| 63 6f 6c 6f 72 20 69 73 | 20 74 72 61 6e 73 6c 61 |color is| transla| |00000f60| 74 65 64 20 62 79 20 6c | 69 6e 65 61 72 20 69 6e |ted by l|inear in| |00000f70| 74 65 72 70 6f 6c 61 74 | 69 6f 6e 20 62 65 74 77 |terpolat|ion betw| |00000f80| 65 65 6e 20 74 68 65 0d | 66 6f 72 65 67 72 6f 75 |een the.|foregrou| |00000f90| 6e 64 20 61 6e 64 20 62 | 61 63 6b 67 72 6f 75 6e |nd and b|ackgroun| |00000fa0| 64 20 63 6f 6c 6f 72 2e | 20 50 72 6f 67 72 61 6d |d color.| Program| |00000fb0| 6d 65 72 73 20 6f 66 74 | 65 6e 20 66 6f 72 67 65 |mers oft|en forge| |00000fc0| 74 20 61 62 6f 75 74 20 | 74 68 69 73 2c 20 61 6e |t about |this, an| |00000fd0| 64 20 61 72 65 0d 73 75 | 72 70 72 69 73 65 64 20 |d are.su|rprised | |00000fe0| 62 79 20 74 68 65 20 75 | 6e 64 65 73 69 72 65 64 |by the u|ndesired| |00000ff0| 20 63 6f 6c 6f 72 69 7a | 69 6e 67 2e 20 54 6f 20 | coloriz|ing. To | |00001000| 6d 61 6b 65 20 6c 69 66 | 65 20 65 61 73 69 65 72 |make lif|e easier| |00001010| 20 49 27 76 65 20 64 65 | 66 69 6e 65 64 20 61 6e | I've de|fined an| |00001020| 20 65 78 74 72 61 0d 62 | 69 74 20 69 6e 20 73 72 | extra.b|it in sr| |00001030| 63 4d 6f 64 65 2e 20 49 | 66 20 74 68 65 20 22 63 |cMode. I|f the "c| |00001040| 6f 70 79 43 6f 6c 6f 72 | 69 7a 65 22 20 66 6c 61 |opyColor|ize" fla| |00001050| 67 20 69 73 20 66 61 6c | 73 65 20 28 6e 65 61 72 |g is fal|se (near| |00001060| 6c 79 20 61 6c 77 61 79 | 73 20 74 68 65 20 63 61 |ly alway|s the ca| |00001070| 73 65 29 0d 74 68 65 6e | 20 43 6f 70 79 57 69 6e |se).then| CopyWin| |00001080| 64 6f 77 73 20 77 69 6c | 6c 20 6d 61 6b 65 20 73 |dows wil|l make s| |00001090| 75 72 65 20 6e 6f 20 63 | 6f 6c 6f 72 69 7a 69 6e |ure no c|olorizin| |000010a0| 67 20 6f 63 63 75 72 73 | 20 62 79 20 73 65 74 74 |g occurs| by sett| |000010b0| 69 6e 67 20 74 68 65 20 | 66 6f 72 65 20 61 6e 64 |ing the |fore and| |000010c0| 0d 62 61 63 6b 20 63 6f | 6c 6f 72 73 20 74 6f 20 |.back co|lors to | |000010d0| 62 6c 61 63 6b 20 61 6e | 64 20 77 68 69 74 65 2e |black an|d white.| |000010e0| 20 28 54 68 65 20 63 6f | 6c 6f 72 73 20 61 72 65 | (The co|lors are| |000010f0| 20 72 65 73 74 6f 72 65 | 64 20 62 65 66 6f 72 65 | restore|d before| |00001100| 20 72 65 74 75 72 6e 69 | 6e 67 2e 29 0d 0d 32 2e | returni|ng.)..2.| |00001110| 20 41 70 70 6c 65 27 73 | 20 43 6f 70 79 42 69 74 | Apple's| CopyBit| |00001120| 73 20 75 73 65 73 20 74 | 68 65 20 63 6f 6c 6f 72 |s uses t|he color| |00001130| 20 74 61 62 6c 65 20 61 | 6e 64 20 70 61 6c 65 74 | table a|nd palet| |00001140| 74 65 20 6f 66 20 74 68 | 65 20 73 6f 75 72 63 65 |te of th|e source| |00001150| 20 70 69 78 6d 61 70 20 | 61 73 0d 79 6f 75 27 64 | pixmap |as.you'd| |00001160| 20 65 78 70 65 63 74 2c | 20 62 75 74 20 69 67 6e | expect,| but ign| |00001170| 6f 72 65 73 20 74 68 65 | 20 63 6f 6c 6f 72 20 74 |ores the| color t| |00001180| 61 62 6c 65 20 61 6e 64 | 20 70 61 6c 65 74 74 65 |able and| palette| |00001190| 20 6f 66 20 74 68 65 20 | 64 65 73 74 69 6e 61 74 | of the |destinat| |000011a0| 69 6f 6e 20 70 69 78 6d | 61 70 2c 0d 61 6e 64 20 |ion pixm|ap,.and | |000011b0| 69 6e 73 74 65 61 64 20 | 75 73 65 73 20 74 68 65 |instead |uses the| |000011c0| 20 63 6f 6c 6f 72 20 74 | 61 62 6c 65 20 6f 66 20 | color t|able of | |000011d0| 74 68 65 20 63 75 72 72 | 65 6e 74 20 64 65 76 69 |the curr|ent devi| |000011e0| 63 65 2e 20 54 68 69 73 | 20 69 73 20 61 6e 6e 6f |ce. This| is anno| |000011f0| 79 69 6e 67 2c 20 61 6e | 64 0d 68 61 72 64 20 74 |ying, an|d.hard t| |00001200| 6f 20 72 65 6d 65 6d 62 | 65 72 2e 20 41 70 70 6c |o rememb|er. Appl| |00001210| 65 20 64 69 64 20 69 74 | 20 74 68 69 73 20 77 61 |e did it| this wa| |00001220| 79 20 62 65 63 61 75 73 | 65 20 43 6f 70 79 42 69 |y becaus|e CopyBi| |00001230| 74 73 20 75 73 65 73 20 | 74 68 65 20 69 6e 76 65 |ts uses |the inve| |00001240| 72 73 65 20 63 6f 6c 6f | 72 0d 74 61 62 6c 65 2c |rse colo|r.table,| |00001250| 20 77 68 69 63 68 20 74 | 61 6b 65 73 20 61 20 6c | which t|akes a l| |00001260| 6f 6e 67 20 74 69 6d 65 | 20 74 6f 20 63 6f 6d 70 |ong time| to comp| |00001270| 75 74 65 2c 20 61 6e 64 | 20 74 68 65 79 20 64 65 |ute, and| they de| |00001280| 63 69 64 65 64 20 74 68 | 61 74 20 69 74 20 77 6f |cided th|at it wo| |00001290| 75 6c 64 20 62 65 20 74 | 6f 6f 0d 74 69 6d 65 20 |uld be t|oo.time | |000012a0| 61 6e 64 20 6d 65 6d 6f | 72 79 20 69 6e 74 65 6e |and memo|ry inten| |000012b0| 73 69 76 65 20 74 6f 20 | 6d 61 69 6e 74 61 69 6e |sive to |maintain| |000012c0| 20 61 6e 20 69 6e 76 65 | 72 73 65 20 74 61 62 6c | an inve|rse tabl| |000012d0| 65 20 66 6f 72 20 65 61 | 63 68 20 77 69 6e 64 6f |e for ea|ch windo| |000012e0| 77 2c 20 73 6f 0d 69 6e | 73 74 65 61 64 20 74 68 |w, so.in|stead th| |000012f0| 65 79 20 6d 61 69 6e 74 | 61 69 6e 20 74 68 65 6d |ey maint|ain them| |00001300| 20 6f 6e 6c 79 20 66 6f | 72 20 64 65 76 69 63 65 | only fo|r device| |00001310| 73 2e 20 54 68 65 20 6f | 70 65 72 61 74 69 6e 67 |s. The o|perating| |00001320| 20 73 79 73 74 65 6d 20 | 63 72 65 61 74 65 73 0d | system |creates.| |00001330| 69 6e 76 65 72 73 65 20 | 63 6f 6c 6f 72 20 74 61 |inverse |color ta| |00001340| 62 6c 65 73 20 66 6f 72 | 20 61 6c 6c 20 67 72 61 |bles for| all gra| |00001350| 70 68 69 63 20 64 65 76 | 69 63 65 73 2e 20 54 68 |phic dev|ices. Th| |00001360| 75 73 20 69 74 20 69 73 | 20 69 6d 70 6f 72 74 61 |us it is| importa| |00001370| 6e 74 20 74 6f 20 72 65 | 6d 65 6d 62 65 72 0d 74 |nt to re|member.t| |00001380| 6f 20 73 65 74 20 74 68 | 65 20 64 65 76 69 63 65 |o set th|e device| |00001390| 20 62 65 66 6f 72 65 20 | 63 61 6c 6c 69 6e 67 20 | before |calling | |000013a0| 43 6f 70 79 42 69 74 73 | 2e 20 54 6f 20 73 61 76 |CopyBits|. To sav| |000013b0| 65 20 79 6f 75 20 74 68 | 65 20 74 72 6f 75 62 6c |e you th|e troubl| |000013c0| 65 2c 20 43 6f 70 79 57 | 69 6e 64 6f 77 73 0d 73 |e, CopyW|indows.s| |000013d0| 65 74 73 20 74 68 65 20 | 64 65 76 69 63 65 20 74 |ets the |device t| |000013e0| 6f 20 62 65 20 77 68 61 | 74 65 76 65 72 20 64 65 |o be wha|tever de| |000013f0| 76 69 63 65 20 69 73 20 | 61 73 73 6f 63 69 61 74 |vice is |associat| |00001400| 65 64 20 77 69 74 68 20 | 74 68 65 20 64 65 73 74 |ed with |the dest| |00001410| 69 6e 61 74 69 6f 6e 20 | 77 69 6e 64 6f 77 2e 0d |ination |window..| |00001420| 54 68 65 20 64 65 76 69 | 63 65 20 69 73 20 66 6f |The devi|ce is fo| |00001430| 75 6e 64 20 62 79 20 47 | 65 74 57 69 6e 64 6f 77 |und by G|etWindow| |00001440| 44 65 76 69 63 65 28 29 | 2c 20 77 68 69 63 68 2c |Device()|, which,| |00001450| 20 66 6f 72 20 61 6e 20 | 6f 6e 2d 73 63 72 65 65 | for an |on-scree| |00001460| 6e 20 77 69 6e 64 6f 77 | 2c 0d 72 65 74 75 72 6e |n window|,.return| |00001470| 73 20 74 68 65 20 73 63 | 72 65 65 6e 20 64 65 76 |s the sc|reen dev| |00001480| 69 63 65 20 77 69 74 68 | 20 6c 61 72 67 65 73 74 |ice with| largest| |00001490| 20 69 6e 74 65 72 73 65 | 63 74 69 6f 6e 20 77 69 | interse|ction wi| |000014a0| 74 68 20 74 68 65 20 77 | 69 6e 64 6f 77 27 73 20 |th the w|indow's | |000014b0| 63 6f 6e 74 65 6e 74 2c | 0d 61 6e 64 20 66 6f 72 |content,|.and for| |000014c0| 20 61 6e 20 6f 66 66 2d | 73 63 72 65 65 6e 20 77 | an off-|screen w| |000014d0| 69 6e 64 6f 77 20 28 69 | 2e 65 2e 20 47 57 6f 72 |indow (i|.e. GWor| |000014e0| 6c 64 29 2c 20 72 65 74 | 75 72 6e 73 20 74 68 65 |ld), ret|urns the| |000014f0| 20 47 57 6f 72 6c 64 27 | 73 20 64 65 76 69 63 65 | GWorld'|s device| |00001500| 2e 20 57 68 65 6e 0d 79 | 6f 75 20 63 72 65 61 74 |. When.y|ou creat| |00001510| 65 20 79 6f 75 72 20 47 | 57 6f 72 6c 64 20 79 6f |e your G|World yo| |00001520| 75 20 73 68 6f 75 6c 64 | 20 73 75 70 70 6c 79 20 |u should| supply | |00001530| 74 68 65 20 63 6f 6c 6f | 72 20 74 61 62 6c 65 20 |the colo|r table | |00001540| 6f 66 20 79 6f 75 72 20 | 64 65 76 69 63 65 2c 20 |of your |device, | |00001550| 0d 28 2a 28 2a 64 65 76 | 69 63 65 29 2d 3e 67 64 |.(*(*dev|ice)->gd| |00001560| 50 4d 61 70 29 2d 3e 70 | 6d 54 61 62 6c 65 2c 20 |PMap)->p|mTable, | |00001570| 69 66 20 79 6f 75 27 6c | 6c 20 6c 61 74 65 72 20 |if you'l|l later | |00001580| 62 65 20 63 6f 70 79 69 | 6e 67 20 66 72 6f 6d 20 |be copyi|ng from | |00001590| 74 68 65 20 47 57 6f 72 | 6c 64 0d 74 6f 20 74 68 |the GWor|ld.to th| |000015a0| 65 20 64 65 76 69 63 65 | 2e 0d 0d 33 2e 20 43 6f |e device|...3. Co| |000015b0| 70 79 57 69 6e 64 6f 77 | 73 51 75 69 63 6b 6c 79 |pyWindow|sQuickly| |000015c0| 20 63 61 6c 6c 73 20 53 | 68 69 65 6c 64 43 75 72 | calls S|hieldCur| |000015d0| 73 6f 72 28 29 2c 20 74 | 6f 20 6d 61 6b 65 20 75 |sor(), t|o make u| |000015e0| 70 20 66 6f 72 20 74 68 | 65 20 66 61 63 74 20 74 |p for th|e fact t| |000015f0| 68 61 74 0d 43 6f 70 79 | 42 69 74 73 51 75 69 63 |hat.Copy|BitsQuic| |00001600| 6b 6c 79 20 64 6f 65 73 | 6e 27 74 2e 20 51 75 69 |kly does|n't. Qui| |00001610| 63 6b 44 72 61 77 20 61 | 75 74 6f 6d 61 74 69 63 |ckDraw a|utomatic| |00001620| 61 6c 6c 79 20 63 61 6c | 6c 73 20 53 68 69 65 6c |ally cal|ls Shiel| |00001630| 64 43 75 72 73 6f 72 20 | 66 6f 72 20 61 6c 6c 0d |dCursor |for all.| |00001640| 73 63 72 65 65 6e 2d 64 | 72 61 77 69 6e 67 20 6f |screen-d|rawing o| |00001650| 70 65 72 61 74 69 6f 6e | 73 2c 20 62 75 74 20 43 |peration|s, but C| |00001660| 6f 70 79 42 69 74 73 51 | 75 69 63 6b 6c 79 20 62 |opyBitsQ|uickly b| |00001670| 79 70 61 73 73 65 73 20 | 51 75 69 63 6b 44 72 61 |ypasses |QuickDra| |00001680| 77 2e 20 54 68 65 20 6f | 62 76 69 6f 75 73 0d 63 |w. The o|bvious.c| |00001690| 6f 73 6d 65 74 69 63 20 | 62 65 6e 65 66 69 74 20 |osmetic |benefit | |000016a0| 6f 66 20 63 61 6c 6c 69 | 6e 67 20 53 68 69 65 6c |of calli|ng Shiel| |000016b0| 64 43 75 72 73 6f 72 20 | 69 73 20 74 68 61 74 20 |dCursor |is that | |000016c0| 69 74 20 70 72 65 76 65 | 6e 74 73 20 74 68 65 20 |it preve|nts the | |000016d0| 63 75 72 73 6f 72 20 66 | 72 6f 6d 0d 61 70 70 65 |cursor f|rom.appe| |000016e0| 61 72 69 6e 67 20 77 69 | 74 68 69 6e 20 73 63 72 |aring wi|thin scr| |000016f0| 65 65 6e 20 61 72 65 61 | 73 20 74 68 61 74 20 61 |een area|s that a| |00001700| 72 65 20 62 65 69 6e 67 | 20 72 65 61 64 20 6f 72 |re being| read or| |00001710| 20 77 72 69 74 74 65 6e | 2e 20 41 20 66 75 72 74 | written|. A furt| |00001720| 68 65 72 2c 20 73 75 62 | 74 6c 65 2c 0d 62 65 6e |her, sub|tle,.ben| |00001730| 65 66 69 74 20 6f 66 20 | 63 61 6c 6c 69 6e 67 20 |efit of |calling | |00001740| 53 68 69 65 6c 64 43 75 | 72 73 6f 72 20 69 73 20 |ShieldCu|rsor is | |00001750| 63 6f 6d 70 61 74 69 62 | 69 6c 69 74 79 20 77 69 |compatib|ility wi| |00001760| 74 68 20 74 68 65 20 6f | 6e 65 20 6f 72 20 74 77 |th the o|ne or tw| |00001770| 6f 20 76 69 64 65 6f 0d | 64 65 76 69 63 65 73 2c |o video.|devices,| |00001780| 20 65 2e 67 2e 20 52 61 | 64 69 75 73 20 50 6f 77 | e.g. Ra|dius Pow| |00001790| 65 72 56 69 65 77 2c 20 | 74 68 61 74 20 64 65 70 |erView, |that dep| |000017a0| 65 6e 64 20 6f 6e 20 6e | 6f 74 69 66 69 63 61 74 |end on n|otificat| |000017b0| 69 6f 6e 20 66 72 6f 6d | 20 51 75 69 63 6b 44 72 |ion from| QuickDr| |000017c0| 61 77 20 74 68 61 74 0d | 74 68 65 79 27 76 65 20 |aw that.|they've | |000017d0| 62 65 65 6e 20 77 72 69 | 74 74 65 6e 20 74 6f 2e |been wri|tten to.| |000017e0| 20 41 63 63 6f 72 64 69 | 6e 67 20 74 6f 20 74 68 | Accordi|ng to th| |000017f0| 65 20 70 72 6f 67 72 61 | 6d 6d 65 72 20 77 68 6f |e progra|mmer who| |00001800| 20 77 72 6f 74 65 20 74 | 68 65 20 50 6f 77 65 72 | wrote t|he Power| |00001810| 56 69 65 77 0d 64 72 69 | 76 65 72 2c 20 69 74 27 |View.dri|ver, it'| |00001820| 73 20 65 6e 6f 75 67 68 | 20 74 6f 20 63 61 6c 6c |s enough| to call| |00001830| 20 53 68 69 65 6c 64 43 | 75 72 73 6f 72 28 29 2c | ShieldC|ursor(),| |00001840| 20 73 70 65 63 69 66 79 | 69 6e 67 20 74 68 65 20 | specify|ing the | |00001850| 67 6c 6f 62 61 6c 20 72 | 65 63 74 20 74 68 61 74 |global r|ect that| |00001860| 20 77 61 73 0d 6d 6f 64 | 69 66 69 65 64 2e 20 54 | was.mod|ified. T| |00001870| 68 61 74 27 73 20 68 61 | 72 64 20 74 6f 20 64 6f |hat's ha|rd to do| |00001880| 20 77 69 74 68 69 6e 20 | 43 6f 70 79 42 69 74 73 | within |CopyBits| |00001890| 51 75 69 63 6b 6c 79 20 | 62 65 63 61 75 73 65 20 |Quickly |because | |000018a0| 74 68 65 20 50 69 78 4d | 61 70 20 64 6f 65 73 6e |the PixM|ap doesn| |000018b0| 27 74 0d 68 61 76 65 20 | 61 6e 79 20 67 6c 6f 62 |'t.have |any glob| |000018c0| 61 6c 20 63 6f 6f 72 64 | 69 6e 61 74 65 73 3b 20 |al coord|inates; | |000018d0| 69 74 20 6d 65 72 65 6c | 79 20 68 61 73 20 6c 6f |it merel|y has lo| |000018e0| 63 61 6c 20 63 6f 6f 72 | 64 69 6e 61 74 65 73 20 |cal coor|dinates | |000018f0| 61 6e 64 20 74 68 65 20 | 61 64 64 72 65 73 73 20 |and the |address | |00001900| 6f 66 0d 76 69 64 65 6f | 20 6d 65 6d 6f 72 79 2e |of.video| memory.| |00001910| 20 28 4f 6e 65 20 77 6f | 75 6c 64 20 68 61 76 65 | (One wo|uld have| |00001920| 20 74 6f 20 75 73 65 20 | 74 68 65 20 76 69 64 65 | to use |the vide| |00001930| 6f 20 61 64 64 72 65 73 | 73 20 74 6f 20 66 69 67 |o addres|s to fig| |00001940| 75 72 65 20 6f 75 74 20 | 74 68 65 20 64 65 76 69 |ure out |the devi| |00001950| 63 65 2c 0d 61 6e 64 20 | 67 65 74 20 74 68 65 20 |ce,.and |get the | |00001960| 67 6c 6f 62 61 6c 20 63 | 6f 6f 72 64 69 6e 61 74 |global c|oordinat| |00001970| 65 73 20 66 72 6f 6d 20 | 74 68 65 20 64 65 76 69 |es from |the devi| |00001980| 63 65 2e 29 20 42 75 74 | 20 69 74 27 73 20 65 61 |ce.) But| it's ea| |00001990| 73 79 20 74 6f 20 63 61 | 6c 6c 0d 53 68 69 65 6c |sy to ca|ll.Shiel| |000019a0| 64 43 75 72 73 6f 72 20 | 66 72 6f 6d 20 77 69 74 |dCursor |from wit| |000019b0| 68 69 6e 20 43 6f 70 79 | 57 69 6e 64 6f 77 73 51 |hin Copy|WindowsQ| |000019c0| 75 69 63 6b 6c 79 2c 20 | 73 69 6e 63 65 20 69 74 |uickly, |since it| |000019d0| 20 68 61 73 20 61 63 63 | 65 73 73 20 74 6f 20 74 | has acc|ess to t| |000019e0| 68 65 20 77 69 6e 64 6f | 77 73 2c 0d 77 68 69 63 |he windo|ws,.whic| |000019f0| 68 20 69 6e 63 6c 75 64 | 65 20 74 68 65 20 6e 65 |h includ|e the ne| |00001a00| 63 65 73 73 61 72 79 20 | 67 6c 6f 62 61 6c 20 63 |cessary |global c| |00001a10| 6f 6f 72 64 69 6e 61 74 | 65 73 2e 0d 0d 48 49 53 |oordinat|es...HIS| |00001a20| 54 4f 52 59 3a 0d 31 30 | 2f 33 2f 39 34 20 64 67 |TORY:.10|/3/94 dg| |00001a30| 70 20 77 72 6f 74 65 20 | 69 74 2e 0d 31 31 2f 35 |p wrote |it..11/5| |00001a40| 2f 39 34 20 64 67 70 20 | 61 64 64 65 64 20 74 68 |/94 dgp |added th| |00001a50| 65 20 6e 65 77 20 66 6c | 61 67 73 20 63 6f 70 79 |e new fl|ags copy| |00001a60| 4c 69 74 65 72 61 6c 6c | 79 20 61 6e 64 20 63 6f |Literall|y and co| |00001a70| 70 79 43 6f 6c 6f 72 69 | 7a 65 2e 0d 2a 2f 0d 23 |pyColori|ze..*/.#| |00001a80| 69 6e 63 6c 75 64 65 20 | 22 56 69 64 65 6f 54 6f |include |"VideoTo| |00001a90| 6f 6c 62 6f 78 2e 68 22 | 0d 23 69 6e 63 6c 75 64 |olbox.h"|.#includ| |00001aa0| 65 20 3c 51 75 69 63 6b | 44 72 61 77 2e 68 3e 0d |e <Quick|Draw.h>.| |00001ab0| 73 74 61 74 69 63 20 69 | 6e 74 20 43 6f 70 79 57 |static i|nt CopyW| |00001ac0| 69 6e 64 6f 77 73 51 75 | 69 63 6b 6c 79 28 43 57 |indowsQu|ickly(CW| |00001ad0| 69 6e 64 6f 77 50 74 72 | 20 73 72 63 57 69 6e 64 |indowPtr| srcWind| |00001ae0| 6f 77 2c 43 57 69 6e 64 | 6f 77 50 74 72 20 64 73 |ow,CWind|owPtr ds| |00001af0| 74 57 69 6e 64 6f 77 0d | 09 2c 52 65 63 74 20 2a |tWindow.|.,Rect *| |00001b00| 73 72 63 52 65 63 74 50 | 74 72 2c 52 65 63 74 20 |srcRectP|tr,Rect | |00001b10| 2a 64 73 74 52 65 63 74 | 50 74 72 2c 6c 6f 6e 67 |*dstRect|Ptr,long| |00001b20| 20 73 72 63 4d 6f 64 65 | 2c 52 67 6e 48 61 6e 64 | srcMode|,RgnHand| |00001b30| 6c 65 20 6d 61 73 6b 52 | 67 6e 29 3b 0d 0d 69 6e |le maskR|gn);..in| |00001b40| 74 20 43 6f 70 79 57 69 | 6e 64 6f 77 73 28 43 57 |t CopyWi|ndows(CW| |00001b50| 69 6e 64 6f 77 50 74 72 | 20 73 72 63 57 69 6e 64 |indowPtr| srcWind| |00001b60| 6f 77 2c 43 57 69 6e 64 | 6f 77 50 74 72 20 64 73 |ow,CWind|owPtr ds| |00001b70| 74 57 69 6e 64 6f 77 0d | 09 2c 52 65 63 74 20 2a |tWindow.|.,Rect *| |00001b80| 73 72 63 52 65 63 74 50 | 74 72 2c 52 65 63 74 20 |srcRectP|tr,Rect | |00001b90| 2a 64 73 74 52 65 63 74 | 50 74 72 2c 6c 6f 6e 67 |*dstRect|Ptr,long| |00001ba0| 20 73 72 63 4d 6f 64 65 | 2c 52 67 6e 48 61 6e 64 | srcMode|,RgnHand| |00001bb0| 6c 65 20 6d 61 73 6b 52 | 67 6e 29 0d 7b 0d 09 47 |le maskR|gn).{..G| |00001bc0| 57 6f 72 6c 64 50 74 72 | 20 6f 6c 64 50 6f 72 74 |WorldPtr| oldPort| |00001bd0| 3b 0d 09 47 44 48 61 6e | 64 6c 65 20 6f 6c 64 44 |;..GDHan|dle oldD| |00001be0| 65 76 69 63 65 2c 64 65 | 76 69 63 65 3b 0d 09 69 |evice,de|vice;..i| |00001bf0| 6e 74 20 65 72 72 6f 72 | 3b 0d 20 20 20 20 73 74 |nt error|;. st| |00001c00| 61 74 69 63 20 63 6f 6e | 73 74 20 52 47 42 43 6f |atic con|st RGBCo| |00001c10| 6c 6f 72 20 62 6c 61 63 | 6b 52 47 42 3d 7b 30 2c |lor blac|kRGB={0,| |00001c20| 30 2c 30 7d 2c 77 68 69 | 74 65 52 47 42 3d 7b 30 |0,0},whi|teRGB={0| |00001c30| 78 46 46 46 46 2c 30 78 | 46 46 46 46 2c 30 78 46 |xFFFF,0x|FFFF,0xF| |00001c40| 46 46 46 7d 3b 0d 09 52 | 47 42 43 6f 6c 6f 72 20 |FFF};..R|GBColor | |00001c50| 66 6f 72 65 52 47 42 2c | 62 61 63 6b 52 47 42 3b |foreRGB,|backRGB;| |00001c60| 0d 20 20 20 20 43 6f 6c | 6f 72 53 70 65 63 20 66 |. Col|orSpec f| |00001c70| 6f 72 65 43 6f 6c 6f 72 | 2c 62 61 63 6b 43 6f 6c |oreColor|,backCol| |00001c80| 6f 72 3b 0d 09 42 69 74 | 4d 61 70 20 2a 73 72 63 |or;..Bit|Map *src| |00001c90| 42 69 74 73 2c 2a 64 73 | 74 42 69 74 73 3b 0d 09 |Bits,*ds|tBits;..| |00001ca0| 73 74 61 74 69 63 20 42 | 6f 6f 6c 65 61 6e 20 71 |static B|oolean q| |00001cb0| 64 38 2c 71 64 33 32 2c | 66 69 72 73 74 54 69 6d |d8,qd32,|firstTim| |00001cc0| 65 3d 31 3b 0d 09 42 6f | 6f 6c 65 61 6e 20 63 6f |e=1;..Bo|olean co| |00001cd0| 6c 6f 72 69 7a 65 3b 0d | 09 0d 09 69 66 28 73 72 |lorize;.|...if(sr| |00001ce0| 63 4d 6f 64 65 20 26 20 | 63 6f 70 79 4c 69 74 65 |cMode & |copyLite| |00001cf0| 72 61 6c 6c 79 29 0d 09 | 09 72 65 74 75 72 6e 20 |rally)..|.return | |00001d00| 43 6f 70 79 57 69 6e 64 | 6f 77 73 51 75 69 63 6b |CopyWind|owsQuick| |00001d10| 6c 79 28 73 72 63 57 69 | 6e 64 6f 77 2c 64 73 74 |ly(srcWi|ndow,dst| |00001d20| 57 69 6e 64 6f 77 2c 73 | 72 63 52 65 63 74 50 74 |Window,s|rcRectPt| |00001d30| 72 2c 64 73 74 52 65 63 | 74 50 74 72 2c 73 72 63 |r,dstRec|tPtr,src| |00001d40| 4d 6f 64 65 2c 6d 61 73 | 6b 52 67 6e 29 3b 0d 09 |Mode,mas|kRgn);..| |00001d50| 63 6f 6c 6f 72 69 7a 65 | 3d 28 73 72 63 4d 6f 64 |colorize|=(srcMod| |00001d60| 65 26 63 6f 70 79 43 6f | 6c 6f 72 69 7a 65 29 21 |e©Co|lorize)!| |00001d70| 3d 30 3b 0d 09 73 72 63 | 4d 6f 64 65 26 3d 30 78 |=0;..src|Mode&=0x| |00001d80| 66 66 66 66 3b 09 2f 2f | 20 6e 6f 20 6d 6f 72 65 |ffff;.//| no more| |00001d90| 20 6e 65 65 64 20 66 6f | 72 20 75 70 70 65 72 20 | need fo|r upper | |00001da0| 62 69 74 73 2e 0d 09 69 | 66 28 66 69 72 73 74 54 |bits...i|f(firstT| |00001db0| 69 6d 65 29 7b 0d 09 09 | 6c 6f 6e 67 20 71 64 3b |ime){...|long qd;| |00001dc0| 0d 09 09 47 65 73 74 61 | 6c 74 28 67 65 73 74 61 |...Gesta|lt(gesta| |00001dd0| 6c 74 51 75 69 63 6b 64 | 72 61 77 56 65 72 73 69 |ltQuickd|rawVersi| |00001de0| 6f 6e 2c 26 71 64 29 3b | 0d 09 09 71 64 38 20 3d |on,&qd);|...qd8 =| |00001df0| 20 71 64 3e 3d 67 65 73 | 74 61 6c 74 38 42 69 74 | qd>=ges|talt8Bit| |00001e00| 51 44 3b 0d 09 09 71 64 | 33 32 20 3d 20 71 64 3e |QD;...qd|32 = qd>| |00001e10| 3d 67 65 73 74 61 6c 74 | 33 32 42 69 74 51 44 3b |=gestalt|32BitQD;| |00001e20| 0d 09 09 66 69 72 73 74 | 54 69 6d 65 3d 30 3b 0d |...first|Time=0;.| |00001e30| 09 7d 0d 09 64 65 76 69 | 63 65 3d 47 65 74 57 69 |.}..devi|ce=GetWi| |00001e40| 6e 64 6f 77 44 65 76 69 | 63 65 28 28 57 69 6e 64 |ndowDevi|ce((Wind| |00001e50| 6f 77 50 74 72 29 64 73 | 74 57 69 6e 64 6f 77 29 |owPtr)ds|tWindow)| |00001e60| 3b 0d 09 69 66 28 71 64 | 33 32 29 7b 0d 09 09 47 |;..if(qd|32){...G| |00001e70| 65 74 47 57 6f 72 6c 64 | 28 26 6f 6c 64 50 6f 72 |etGWorld|(&oldPor| |00001e80| 74 2c 26 6f 6c 64 44 65 | 76 69 63 65 29 3b 0d 09 |t,&oldDe|vice);..| |00001e90| 09 53 65 74 47 57 6f 72 | 6c 64 28 28 47 57 6f 72 |.SetGWor|ld((GWor| |00001ea0| 6c 64 50 74 72 29 64 73 | 74 57 69 6e 64 6f 77 2c |ldPtr)ds|tWindow,| |00001eb0| 64 65 76 69 63 65 29 3b | 0d 09 7d 65 6c 73 65 7b |device);|..}else{| |00001ec0| 0d 09 09 47 65 74 50 6f | 72 74 28 28 57 69 6e 64 |...GetPo|rt((Wind| |00001ed0| 6f 77 50 74 72 20 2a 29 | 26 6f 6c 64 50 6f 72 74 |owPtr *)|&oldPort| |00001ee0| 29 3b 0d 09 09 53 65 74 | 50 6f 72 74 28 28 57 69 |);...Set|Port((Wi| |00001ef0| 6e 64 6f 77 50 74 72 29 | 64 73 74 57 69 6e 64 6f |ndowPtr)|dstWindo| |00001f00| 77 29 3b 0d 09 09 69 66 | 28 71 64 38 29 7b 0d 09 |w);...if|(qd8){..| |00001f10| 09 09 6f 6c 64 44 65 76 | 69 63 65 3d 47 65 74 47 |..oldDev|ice=GetG| |00001f20| 44 65 76 69 63 65 28 29 | 3b 0d 09 09 09 53 65 74 |Device()|;....Set| |00001f30| 47 44 65 76 69 63 65 28 | 64 65 76 69 63 65 29 3b |GDevice(|device);| |00001f40| 0d 09 09 7d 0d 09 7d 0d | 09 69 66 28 21 63 6f 6c |...}..}.|.if(!col| |00001f50| 6f 72 69 7a 65 20 26 26 | 20 71 64 38 29 7b 0d 09 |orize &&| qd8){..| |00001f60| 09 47 65 74 46 6f 72 65 | 43 6f 6c 6f 72 28 26 66 |.GetFore|Color(&f| |00001f70| 6f 72 65 52 47 42 29 3b | 0d 09 09 47 65 74 42 61 |oreRGB);|...GetBa| |00001f80| 63 6b 43 6f 6c 6f 72 28 | 26 62 61 63 6b 52 47 42 |ckColor(|&backRGB| |00001f90| 29 3b 0d 09 09 69 66 28 | 71 64 33 32 29 7b 0d 09 |);...if(|qd32){..| |00001fa0| 09 09 53 61 76 65 46 6f | 72 65 28 26 66 6f 72 65 |..SaveFo|re(&fore| |00001fb0| 43 6f 6c 6f 72 29 3b 0d | 09 09 09 53 61 76 65 42 |Color);.|...SaveB| |00001fc0| 61 63 6b 28 26 62 61 63 | 6b 43 6f 6c 6f 72 29 3b |ack(&bac|kColor);| |00001fd0| 0d 09 09 7d 0d 09 09 52 | 47 42 46 6f 72 65 43 6f |...}...R|GBForeCo| |00001fe0| 6c 6f 72 28 26 62 6c 61 | 63 6b 52 47 42 29 3b 20 |lor(&bla|ckRGB); | |00001ff0| 20 2f 2a 20 73 6f 20 43 | 6f 70 79 42 69 74 73 20 | /* so C|opyBits | |00002000| 77 6f 6e 27 74 20 63 6f | 6c 6f 72 69 7a 65 20 20 |won't co|lorize | |00002010| 2a 2f 0d 09 09 52 47 42 | 42 61 63 6b 43 6f 6c 6f |*/...RGB|BackColo| |00002020| 72 28 26 77 68 69 74 65 | 52 47 42 29 3b 20 20 2f |r(&white|RGB); /| |00002030| 2a 20 73 6f 20 43 6f 70 | 79 42 69 74 73 20 77 6f |* so Cop|yBits wo| |00002040| 6e 27 74 20 63 6f 6c 6f | 72 69 7a 65 20 20 2a 2f |n't colo|rize */| |00002050| 0d 09 7d 0d 09 73 72 63 | 42 69 74 73 3d 47 65 74 |..}..src|Bits=Get| |00002060| 42 69 74 4d 61 70 50 74 | 72 28 73 72 63 57 69 6e |BitMapPt|r(srcWin| |00002070| 64 6f 77 29 3b 0d 09 64 | 73 74 42 69 74 73 3d 47 |dow);..d|stBits=G| |00002080| 65 74 42 69 74 4d 61 70 | 50 74 72 28 64 73 74 57 |etBitMap|Ptr(dstW| |00002090| 69 6e 64 6f 77 29 3b 0d | 09 69 66 28 73 72 63 42 |indow);.|.if(srcB| |000020a0| 69 74 73 3d 3d 4e 55 4c | 4c 20 7c 7c 20 64 73 74 |its==NUL|L || dst| |000020b0| 42 69 74 73 3d 3d 4e 55 | 4c 4c 29 72 65 74 75 72 |Bits==NU|LL)retur| |000020c0| 6e 20 2d 31 3b 0d 09 43 | 6f 70 79 42 69 74 73 28 |n -1;..C|opyBits(| |000020d0| 73 72 63 42 69 74 73 2c | 64 73 74 42 69 74 73 2c |srcBits,|dstBits,| |000020e0| 73 72 63 52 65 63 74 50 | 74 72 2c 64 73 74 52 65 |srcRectP|tr,dstRe| |000020f0| 63 74 50 74 72 2c 73 72 | 63 4d 6f 64 65 2c 6d 61 |ctPtr,sr|cMode,ma| |00002100| 73 6b 52 67 6e 29 3b 0d | 09 65 72 72 6f 72 3d 51 |skRgn);.|.error=Q| |00002110| 44 45 72 72 6f 72 28 29 | 3b 0d 09 69 66 28 21 63 |DError()|;..if(!c| |00002120| 6f 6c 6f 72 69 7a 65 20 | 26 26 20 71 64 38 29 7b |olorize |&& qd8){| |00002130| 0d 09 09 52 47 42 46 6f | 72 65 43 6f 6c 6f 72 28 |...RGBFo|reColor(| |00002140| 26 66 6f 72 65 52 47 42 | 29 3b 0d 09 09 52 47 42 |&foreRGB|);...RGB| |00002150| 42 61 63 6b 43 6f 6c 6f | 72 28 26 62 61 63 6b 52 |BackColo|r(&backR| |00002160| 47 42 29 3b 0d 09 09 69 | 66 28 71 64 33 32 29 7b |GB);...i|f(qd32){| |00002170| 0d 09 09 09 52 65 73 74 | 6f 72 65 46 6f 72 65 28 |....Rest|oreFore(| |00002180| 26 66 6f 72 65 43 6f 6c | 6f 72 29 3b 0d 09 09 09 |&foreCol|or);....| |00002190| 52 65 73 74 6f 72 65 42 | 61 63 6b 28 26 62 61 63 |RestoreB|ack(&bac| |000021a0| 6b 43 6f 6c 6f 72 29 3b | 0d 09 09 7d 0d 09 7d 0d |kColor);|...}..}.| |000021b0| 09 69 66 28 71 64 33 32 | 29 7b 0d 09 09 53 65 74 |.if(qd32|){...Set| |000021c0| 47 57 6f 72 6c 64 28 6f | 6c 64 50 6f 72 74 2c 6f |GWorld(o|ldPort,o| |000021d0| 6c 64 44 65 76 69 63 65 | 29 3b 0d 09 7d 65 6c 73 |ldDevice|);..}els| |000021e0| 65 7b 0d 09 09 53 65 74 | 50 6f 72 74 28 28 57 69 |e{...Set|Port((Wi| |000021f0| 6e 64 6f 77 50 74 72 29 | 6f 6c 64 50 6f 72 74 29 |ndowPtr)|oldPort)| |00002200| 3b 0d 09 09 69 66 28 71 | 64 38 29 53 65 74 47 44 |;...if(q|d8)SetGD| |00002210| 65 76 69 63 65 28 6f 6c | 64 44 65 76 69 63 65 29 |evice(ol|dDevice)| |00002220| 3b 0d 09 7d 0d 09 72 65 | 74 75 72 6e 20 65 72 72 |;..}..re|turn err| |00002230| 6f 72 3b 0d 7d 0d 0d 73 | 74 61 74 69 63 20 69 6e |or;.}..s|tatic in| |00002240| 74 20 43 6f 70 79 57 69 | 6e 64 6f 77 73 51 75 69 |t CopyWi|ndowsQui| |00002250| 63 6b 6c 79 28 43 57 69 | 6e 64 6f 77 50 74 72 20 |ckly(CWi|ndowPtr | |00002260| 73 72 63 57 69 6e 64 6f | 77 2c 43 57 69 6e 64 6f |srcWindo|w,CWindo| |00002270| 77 50 74 72 20 64 73 74 | 57 69 6e 64 6f 77 0d 09 |wPtr dst|Window..| |00002280| 2c 52 65 63 74 20 2a 73 | 72 63 52 65 63 74 50 74 |,Rect *s|rcRectPt| |00002290| 72 2c 52 65 63 74 20 2a | 64 73 74 52 65 63 74 50 |r,Rect *|dstRectP| |000022a0| 74 72 2c 6c 6f 6e 67 20 | 73 72 63 4d 6f 64 65 2c |tr,long |srcMode,| |000022b0| 52 67 6e 48 61 6e 64 6c | 65 20 6d 61 73 6b 52 67 |RgnHandl|e maskRg| |000022c0| 6e 29 0d 7b 0d 09 69 6e | 74 20 65 72 72 6f 72 2c |n).{..in|t error,| |000022d0| 69 2c 73 68 69 65 6c 64 | 73 3d 30 3b 0d 09 42 69 |i,shield|s=0;..Bi| |000022e0| 74 4d 61 70 20 2a 73 72 | 63 42 69 74 73 2c 2a 64 |tMap *sr|cBits,*d| |000022f0| 73 74 42 69 74 73 3b 0d | 09 50 6f 69 6e 74 20 70 |stBits;.|.Point p| |00002300| 74 3b 0d 09 57 69 6e 64 | 6f 77 50 74 72 20 6f 6c |t;..Wind|owPtr ol| |00002310| 64 50 6f 72 74 3b 0d 09 | 0d 09 47 65 74 50 6f 72 |dPort;..|..GetPor| |00002320| 74 28 26 6f 6c 64 50 6f | 72 74 29 3b 0d 09 69 66 |t(&oldPo|rt);..if| |00002330| 28 21 49 73 47 57 6f 72 | 6c 64 50 74 72 28 73 72 |(!IsGWor|ldPtr(sr| |00002340| 63 57 69 6e 64 6f 77 29 | 29 7b 0d 09 09 53 65 74 |cWindow)|){...Set| |00002350| 50 6f 72 74 28 28 57 69 | 6e 64 6f 77 50 74 72 29 |Port((Wi|ndowPtr)| |00002360| 73 72 63 57 69 6e 64 6f | 77 29 3b 0d 09 09 70 74 |srcWindo|w);...pt| |00002370| 2e 68 3d 70 74 2e 76 3d | 30 3b 0d 09 09 4c 6f 63 |.h=pt.v=|0;...Loc| |00002380| 61 6c 54 6f 47 6c 6f 62 | 61 6c 28 26 70 74 29 3b |alToGlob|al(&pt);| |00002390| 0d 09 09 53 68 69 65 6c | 64 43 75 72 73 6f 72 28 |...Shiel|dCursor(| |000023a0| 73 72 63 52 65 63 74 50 | 74 72 2c 70 74 29 3b 0d |srcRectP|tr,pt);.| |000023b0| 09 09 73 68 69 65 6c 64 | 73 2b 2b 3b 0d 09 7d 0d |..shield|s++;..}.| |000023c0| 09 69 66 28 21 49 73 47 | 57 6f 72 6c 64 50 74 72 |.if(!IsG|WorldPtr| |000023d0| 28 64 73 74 57 69 6e 64 | 6f 77 29 29 7b 0d 09 09 |(dstWind|ow)){...| |000023e0| 53 65 74 50 6f 72 74 28 | 28 57 69 6e 64 6f 77 50 |SetPort(|(WindowP| |000023f0| 74 72 29 64 73 74 57 69 | 6e 64 6f 77 29 3b 0d 09 |tr)dstWi|ndow);..| |00002400| 09 70 74 2e 68 3d 70 74 | 2e 76 3d 30 3b 0d 09 09 |.pt.h=pt|.v=0;...| |00002410| 4c 6f 63 61 6c 54 6f 47 | 6c 6f 62 61 6c 28 26 70 |LocalToG|lobal(&p| |00002420| 74 29 3b 0d 09 09 53 68 | 69 65 6c 64 43 75 72 73 |t);...Sh|ieldCurs| |00002430| 6f 72 28 64 73 74 52 65 | 63 74 50 74 72 2c 70 74 |or(dstRe|ctPtr,pt| |00002440| 29 3b 0d 09 09 73 68 69 | 65 6c 64 73 2b 2b 3b 0d |);...shi|elds++;.| |00002450| 09 7d 0d 09 53 65 74 50 | 6f 72 74 28 6f 6c 64 50 |.}..SetP|ort(oldP| |00002460| 6f 72 74 29 3b 0d 09 73 | 72 63 42 69 74 73 3d 47 |ort);..s|rcBits=G| |00002470| 65 74 42 69 74 4d 61 70 | 50 74 72 28 73 72 63 57 |etBitMap|Ptr(srcW| |00002480| 69 6e 64 6f 77 29 3b 0d | 09 64 73 74 42 69 74 73 |indow);.|.dstBits| |00002490| 3d 47 65 74 42 69 74 4d | 61 70 50 74 72 28 64 73 |=GetBitM|apPtr(ds| |000024a0| 74 57 69 6e 64 6f 77 29 | 3b 0d 09 69 66 28 73 72 |tWindow)|;..if(sr| |000024b0| 63 42 69 74 73 3d 3d 4e | 55 4c 4c 20 7c 7c 20 64 |cBits==N|ULL || d| |000024c0| 73 74 42 69 74 73 3d 3d | 4e 55 4c 4c 29 72 65 74 |stBits==|NULL)ret| |000024d0| 75 72 6e 20 34 3b 0d 09 | 65 72 72 6f 72 3d 43 6f |urn 4;..|error=Co| |000024e0| 70 79 42 69 74 73 51 75 | 69 63 6b 6c 79 28 73 72 |pyBitsQu|ickly(sr| |000024f0| 63 42 69 74 73 2c 64 73 | 74 42 69 74 73 2c 73 72 |cBits,ds|tBits,sr| |00002500| 63 52 65 63 74 50 74 72 | 2c 64 73 74 52 65 63 74 |cRectPtr|,dstRect| |00002510| 50 74 72 2c 73 72 63 4d | 6f 64 65 2c 6d 61 73 6b |Ptr,srcM|ode,mask| |00002520| 52 67 6e 29 3b 0d 09 66 | 6f 72 28 69 3d 30 3b 69 |Rgn);..f|or(i=0;i| |00002530| 3c 73 68 69 65 6c 64 73 | 3b 69 2b 2b 29 53 68 6f |<shields|;i++)Sho| |00002540| 77 43 75 72 73 6f 72 28 | 29 3b 0d 09 72 65 74 75 |wCursor(|);..retu| |00002550| 72 6e 20 65 72 72 6f 72 | 3b 0d 7d 0d 0d 00 00 00 |rn error|;.}.....| |00002560| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........| |00002570| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........| |00002580| 00 00 01 00 00 00 01 c4 | 00 00 00 c4 00 00 00 8e |........|........| |00002590| 00 00 3b 7c 1d 34 2e 35 | 20 73 74 64 69 6e 20 73 |..;|.4.5| stdin s| |000025a0| 68 6f 75 6c 64 20 53 65 | 6c 65 63 74 57 69 6e 64 |hould Se|lectWind| |000025b0| 0d 43 6f 70 79 57 69 6e | 64 6f 77 73 2e 63 02 00 |.CopyWin|dows.c..| |000025c0| 00 00 50 61 72 74 53 49 | 54 21 00 00 00 00 00 00 |..PartSI|T!......| |000025d0| 00 00 50 61 72 74 53 49 | 54 21 00 00 00 00 00 00 |..PartSI|T!......| |000025e0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........| |000025f0| 00 00 ab bf ee 5a 00 00 | 00 00 00 00 02 52 00 01 |.....Z..|.....R..| |00002600| 00 00 00 00 00 00 00 00 | 24 3f 00 01 00 00 00 00 |........|$?......| |00002610| 00 00 00 00 00 00 00 00 | 1f 00 00 00 3b 7c 19 34 |........|....;|.4| |00002620| 2e 35 20 73 74 64 69 6f | 20 5c 72 20 61 6e 64 20 |.5 stdio| \r and | |00002630| 5c 6e 20 72 65 63 61 70 | 02 00 02 00 54 45 58 54 |\n recap|....TEXT| |00002640| 51 45 44 31 01 00 ff ff | ff ff 00 00 00 00 41 0c |QED1....|......A.| |00002650| 00 00 00 00 1e ae 00 00 | 2c 00 00 00 00 00 00 00 |........|,.......| |00002660| 00 00 00 00 aa b5 de 2d | aa b5 de 2e 00 00 00 00 |.......-|........| |00002670| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........| |00002680| 00 00 00 1e 00 2a 00 03 | 01 81 01 ff 00 2a 00 03 |.....*..|.....*..| |00002690| 01 6b 01 3a 00 00 00 00 | 00 00 00 00 00 00 00 00 |.k.:....|........| |000026a0| 00 00 00 00 00 2a 00 09 | 06 47 65 6e 65 76 61 00 |.....*..|.Geneva.| |000026b0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........| |000026c0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........| |000026d0| 00 00 00 04 00 06 00 04 | 00 00 00 14 00 00 00 52 |........|.......R| |000026e0| 00 12 ff f4 00 0c ff ff | 00 00 04 1a 00 00 04 22 |........|......."| |000026f0| 00 00 00 48 00 09 4d 6f | 6e 61 63 6f 00 00 00 00 |...H..Mo|naco....| |00002700| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........| |00002710| 00 00 00 00 00 00 00 03 | 00 04 00 3c 00 03 01 8c |........|...<....| |00002720| 02 7d 00 3c 00 03 01 8c | 02 7d ab 94 89 95 00 00 |.}.<....|.}......| |00002730| 0a 5e 00 00 0a 6e 00 00 | 06 bd 00 00 00 00 00 04 |.^...n..|........| |00002740| 00 01 00 01 00 00 01 00 | 00 00 01 c4 00 00 00 c4 |........|........| |00002750| 00 00 00 8e 00 71 4c 48 | 29 80 00 00 00 1c 00 8e |.....qLH|).......| |00002760| 00 04 4d 50 53 52 00 01 | 00 2a 45 46 4e 54 00 00 |..MPSR..|.*EFNT..| |00002770| 00 42 45 54 41 42 00 00 | 00 4e 45 51 45 44 00 00 |.BETAB..|.NEQED..| |00002780| 00 5a 4d 57 42 42 00 00 | 00 66 03 f0 ff ff 00 00 |.ZMWBB..|.f......| |00002790| 00 00 00 00 00 00 03 ed | ff ff 00 00 00 70 00 00 |........|.....p..| |000027a0| 00 00 03 eb ff ff 00 00 | 00 22 00 00 00 00 03 ec |........|."......| |000027b0| ff ff 00 00 00 50 00 00 | 00 00 03 eb ff ff 00 00 |.....P..|........| |000027c0| 00 58 00 00 00 00 03 f0 | ff ff 00 00 00 bc 00 00 |.X......|........| |000027d0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........| |000027e0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........| |000027f0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........| +--------+-------------------------+-------------------------+--------+--------+